package cn.wolfcode.crm.query;

import cn.wolfcode.crm.domain.Employee;
import lombok.Getter;
import lombok.Setter;
import lombok.ToString;
import org.apache.shiro.SecurityUtils;

@Getter
@Setter
@ToString
public class NoticeQueryObject extends QueryObject{
   Employee employee = (Employee) SecurityUtils.getSubject().getPrincipal();
    private Long employeeId = employee.getId() ;
    // 用户传递的两个参数
    // 当前页
    private int currentPage = 1;
    // 每页显示多少条数据
    private int pageSize = 3;
    public int getBeginIndex(){
        return (currentPage - 1) * pageSize;
    }

}
